package cn.topcodes.tcsf.app.web.controller.admin;

import cn.topcodes.tcsf.admin.commons.api.domain.ApiResponseEntity;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * @author Unicorn
 * @date 2017/6/7
 */
@Controller
@RequestMapping("/admin/push")
public class PushAdminController {

    @RequestMapping(value = "",method = RequestMethod.GET)
    public String index() {
        return "admin/push/index";
    }

    /*获取在线APP用户*/
    @ResponseBody
    @RequestMapping(value = "get-online-app-user",method = RequestMethod.GET)
    public ApiResponseEntity getOnlineAppUser() {

        return ApiResponseEntity.buildOK();
    }

    /*推送消息到APP用户*/
    @ResponseBody
    @RequestMapping(value = "push",method = RequestMethod.POST)
    public ApiResponseEntity push(@RequestParam Long id) {

        return ApiResponseEntity.buildOK();
    }
}
